<!-- Google Search Modal -->
<div class="modal-dialog">
    <!-- Modal content-->
    <div class="modal-content">
      <div id="closeSearch" title="Close" class="close">X</div>
      <div class="modal-header">
        <div class="modal-title">
          {{- if $.Site.Params.search.google.title -}}
            {{ $.Site.Params.search.google.title }}
          {{- else -}}
            Search
          {{- end -}}
        </div>
      </div>
      <div class="modal-body">
          <script>
            (function() {
              var cx = '{{ .Site.Params.search.google.id }}';
              var gcse = document.createElement('script');
              gcse.type = 'text/javascript';
              gcse.async = true;
              gcse.src = (document.location.protocol == 'https:' ? 'https:' :
                  'http:') +
                '//cse.google.com/cse.js?cx=' + cx;
              var s = document.getElementsByTagName('script')[0];
              s.parentNode.insertBefore(gcse, s);
            })();
          </script>
          <gcse:search></gcse:search>
      </div>
    </div>
</div>
